import http from "../utils/http";

// 获取我的项目信息
export const getMyProjectInfoService = () => {
  return http.get("/project/projectinfo");
};

// 获取项目申请人数量
export const getProjectApplicationCountService = (projectId) => {
  return http.get(`/project/projectjoin/${projectId}`);
};

// 获取项目详情（用于获取阅读量）
export const getProjectDetailsService = (projectId) => {
  return http.get(`/project/projectById/${projectId}`);
};

// 删除项目
export const deleteProjectService = (projectId, data) => {
  return http.post(`/project/delectproject/${projectId}`, data);
};

// 更新项目状态
export const updateProjectStatusService = (projectId, data) => {
  return http.put(`/project/status/${projectId}`, data);
};